import React from 'react'
import { Col, Row, Card, Table, Space, Modal, Button, Tag } from 'antd';
export default function OperateManage() {
  const columns = [
    {
      title: '序号',
      dataIndex: 'index',
      key: 'index',
      align: "center",
      width: "10%",
      render: (text, record, index) => {
        return <span style={{ fontSize: "12px" }}>{index + 1}</span>
      }
    },
    {
      title: '订单名称',
      dataIndex: 'pointtag',
      key: 'pointtag',
      align: "center",
      render: (text) => {
        return <span style={{ fontSize: "12px" }}>{text}</span>
      }
    },
    {
      title: '订单号',
      dataIndex: 'pointvalue',
      key: 'pointvalue',
      align: "center",
      render: (text) => {
        return <span style={{ fontSize: "12px" }}>{text}</span>
      }
    },
    {
      title: '订单状态',
      dataIndex: 'pointstate',
      key: 'pointstate',
      align: "center",
      render: (text) => {
        return <span style={{ fontSize: "12px" }}>{<Tag color="orange">{text}</Tag>}</span>
      }
    },
    {
      title: '订单时间',
      dataIndex: 'pointunit',
      key: 'pointunit',
      align: "center",
      render: (text) => {
        return <span style={{ fontSize: "12px" }}>{text}</span>
      }
    },
    {
      title: '备注',
      dataIndex: 'comment',
      key: 'comment',
      align: "center",
      render: (text) => {
        return <span style={{ fontSize: "12px" }}>{text}</span>
      }
    },
    {
      title: '操作',
      dataIndex: 'operate',
      key: 'operate',
      fixed: 'right',
      align: "center",
      render: (text, item) => {
        return <Space>
          <a style={{ fontSize: "12px", color: "#4e9dfd" }} onClick={() => { }}>查看</a>
        </Space>
      }
    }
  ];
  const data = [
    {
      id: 1,
      pointtag: "111",
      pointvalue: "12312312",
      pointunit: "2012-05-22 10:00:00",
      comment: "11111",
      pointstate: "进行中"
    }
  ]
  return (
    <div >
      <div><Button type="primary">新增订单</Button></div>
      <Table
        columns={columns} dataSource={data} style={{ margin: "5px 0 0 0" }}
        rowKey={(item) => item.index}
        pagination={{}}
        size='small'
      >
      </Table>
    </div>
  )
}
